package com.example.myapplication.routertest

import androidx.compose.foundation.layout.Column
import androidx.compose.foundation.layout.padding
import androidx.compose.material3.Button
import androidx.compose.material3.Text
import androidx.compose.runtime.Composable
import androidx.compose.ui.Modifier
import androidx.compose.ui.unit.dp
import androidx.compose.ui.unit.sp
import androidx.navigation.NavController

@Composable
fun User(id: Int, navController: NavController) {
    Column(
        modifier = Modifier
            .padding(top = 30.dp)
    ) {
        Text(
            "当前用户id是：$id",
            fontSize = 24.sp,
        )
        Button(
            onClick = {
                navController.popBackStack()
            }
        ) {
            Text("back home")
        }
    }
}